package com.bc.bcmodel.enums;

/**
 * @Name ProjectJoinEnum
 * @Description
 * @Author douhaichao
 * @Date 2018/8/29 11:22
 * @Version 1.0
 **/
public enum SendCoinEnum {
    REGISTERSUCCESS(1,"注册成功并通过KYC"),
    PROJECTSUCCESS(2,"项目方入驻成功"),
    ELITESSUCCESS(3,"成功成为专家")
    ;
    private int value = 0;
    private String desc;
    private SendCoinEnum(int value, String desc) { // 必须是private的，否则编译错误
        this.value = value;
        this.desc = desc;
    }
    public int value() {
        return this.value;
    }
    public String desc() {
        return this.desc;
    }

    public static SendCoinEnum getEnum(int index) {
        for (SendCoinEnum c : SendCoinEnum.values()) {
            if (c.value() == index) {
                return c;
            }
        }
        return null;
    }
}
